<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<title>Medicine Stock Management</title>

	<?php echo css_asset('bootstrap.css'); ?>
	<?php echo css_asset('bootstrap-theme.css'); ?>
	<?php echo js_asset('bootstrap.min.js'); ?>
	
	<script src="https://code.jquery.com/jquery.js"></script>

</head>

<body>
<?php echo js_asset('bootstrap.min.js'); ?>

	<div id="header">
		<div class="half left">
			<div id="lside">
				<ul class="nav nav-pills nav-stacked">
					<li height="50"><a href="<?php echo base_url();?>pro_ctrl/pro_user">
					<b><font color="c9c9c9"><span class="glyphicon glyphicon-user"></span>&nbsp;
					<?php $session_data = $this->session->userdata('logged_in');?>
					<?php echo $session_data['username']; ?></font>
					<span class="navbar-right"><font color="#1ce335">Online&nbsp;
					<span class="glyphicon glyphicon-map-marker"></span></font></span></b></a></li>
					<li class="divider"></li>
				</ul>
			</div>
		</div>

		<div class="half right">
			<nav class="navbar navbar-inverse" role="navigation">
				<!-- Brand and toggle get grouped for better mobile display -->
				<div class="navbar-header">
					<button type="button" class="navbar-toggle" data-toggle="collapse"
						data-target="#bs-example-navbar-collapse-1">
						<span class="sr-only">Toggle navigation</span> <span
							class="icon-bar"></span> <span class="icon-bar"></span> <span
							class="icon-bar"></span>
					</button>
					<a class="navbar-brand">Medicine Stock Management</a>
				</div>

				<!-- Collect the nav links, forms, and other content for toggling -->
				<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
					<ul class="nav navbar-nav">

					</ul>
					
					<ul class="nav navbar-nav navbar-right">
						<li class="dropdown"><a href="#"
							class="dropdown-toggle glyphicon glyphicon-list"
							data-toggle="dropdown"> <b class="caret"></b></a>
							<ul class="dropdown-menu">
								<li><a href="<?php echo base_url();?>pro_ctrl/pro_user">Profile</a></li>
								<li class="divider"></li>
								<li><a href="<?php echo base_url();?>login_control/logout">Logout</a></li>
							</ul></li>
					</ul>
				</div>
				<!-- /.navbar-collapse -->
			</nav>
		</div>
	</div>

	<div id="under_header">
		<div class="half left">
			<div id="lside">
				<div class="list-group" align="center">
					<a class="list-group-item active"><b> Sale </b></a>
				</div>
			</div>
		</div>
		<div class="half right">
			<ol class="breadcrumb">
				<li>&nbsp;</li>
				<li><b>Inventory</b></li>
			</ol>
		</div>
	</div>

	<div id="content">
		<div class="half left">
			<div id="lside">
				<ul class="nav nav-pills nav-stacked">
					<li class="divider"></li>
					<li class="active"><a href="<?php echo base_url();?>sale_ctrl/sale_user">
					<span class="glyphicon glyphicon-stats">&nbsp;&nbsp;</span><b>Inventory</b></a></li>
					<li><a href="<?php echo base_url();?>sol_ctrl/sold_user">
					<span class="glyphicon glyphicon-barcode">&nbsp;&nbsp;</span><b>Sold List</b></a></li>
					<li><br/></li>
				</ul>
				<div class="panel panel-info">
				<div class="panel-heading">
					<h3 class="panel-title"><span class="glyphicon glyphicon-shopping-cart"></span> Cart</h3>
				</div>
				
				<?php for($i=0;$i<count($result);$i++){ ?>
				
				<ul class="list-group">
				  <li class="list-group-item list-group-item"><span class="badge"><?php echo $result[$i]['mdc_amount'];?>
				 <a href=""> <span class="glyphicon glyphicon-remove"></span></a></span>
				 <b><?php echo $i+1;?></b>&nbsp;&nbsp;<?php echo $result[$i]['mdc_name'];?>
				 
				  </li>
				 </ul>
				
				<?php }  ?>
				
				<ul class="nav nav-pills nav-stacked">
					<li><a href="" data-toggle="modal" data-target="#myModal">
					<span class="glyphicon glyphicon-ok">&nbsp;</span><b>Payment</b></a></li>
					<li><a href="" type="reset">
					<span class="glyphicon glyphicon-refresh">&nbsp;</span><b>Reset</b></a></li></li>
				</ul>
				
				<!--<div class="navber-right">
						<button type="button" class="btn btn-primary btn-xs"
							data-toggle="modal" data-target="#myModal">Payment</button>
						<button type="reset" class="btn btn-default btn-xs">Clear</button>
						</div>-->
				</div>
			</div>
		</div>

		<div class="half right">

			<feldset>

			<div class="panel panel-primary">
				<div class="panel-heading">
					<h3 class="panel-title">Stock Detail</h3>
				</div>

								<!-- Modal -->
								<div class="modal fade" id="myModal" tabindex="-1" role="dialog"
									aria-labelledby="myModalLabel" aria-hidden="true">
									<div class="modal-dialog">
										<div class="modal-content">
											<div class="modal-header">
												<button type="button" class="close" data-dismiss="modal"
													aria-hidden="true">&times;</button>
												<h4 class="modal-title" id="myModalLabel">Payment</h4>
											</div>
											<div class="modal-body">

												<form>
													<div class="row">
														<div class="col-lg-4">
															<label>Total : </label><input type="text"
																class="form-control" placeholder="0.00">
														</div>
														<div class="col-lg-4">
															<label>Receive : </label><input type="text"
																class="form-control" placeholder="0.00">
														</div>
														<div class="col-lg-4">
															<label>Change : </label><input type="text"
																class="form-control" placeholder="0.00">
														</div>
														<div class="btn-group">
															<button type="button" class="btn btn-primary">TH</button>
															<button type="button" class="btn btn-warning">EU</button>
															<button type="button" class="btn btn-danger">CH</button>
															</div>
													</div>
												</form>

											</div>
											<div class="modal-footer">
												<button type="button" class="btn btn-default"
													data-dismiss="modal">Cancle</button>
												<button type="button" class="btn btn-primary">Pay</button>
											</div>
										</div>
										<!-- /.modal-content -->
									</div>
									<!-- /.modal-dialog -->
								</div>
								<!-- /.modal -->

				<div class="panel panel-info"> <!-- Default panel contents -->
					<div class="panel-heading"><span class="glyphicon glyphicon-tags"></span>&nbsp; Item list</div>
					<div class="panel-body">

						<form >
							<!--<div class="navbar-form navbar-left" role="search">
								<div class="row">
									<div class="col-lg-6">
										<div class="input-group">
											<input type="text" class="form-control"
												placeholder="Search ..."> <span class="input-group-btn">
												<button class="btn btn-primary" type="button">Search+</button>
											</span>
										</div>--> <!-- /input-group -->
									<!--</div>--> <!-- /.col-lg-6 -->
								<!--</div>--> <!-- /.row -->
							<!--</div>-->
							
								<table class="table table-hover" width="100%">
							<thead>
								<td align="center"><b>#</b></td>
								<td align="center"><b>Drug</b></td>
								<td align="center"><b>Type</b></td>
								<td align="center"><b>Cost</b></td>
								<td align="center"><b>Amount</b></td>
								<td align="center"><b>price1</b></td>
								<td align="center"><b>price2</b></td>
								<td align="center"><b>price3</b></td>
								<td align="center"><b>Date Input</b></td>
								<td align="center"><b>Date Expire</b></td>
								<td align="center"><b>Customize</b></td>
							</thead>
							<tbody>
							
							<?php for($i=0;$i<count($result);$i++){ ?>
							
							
								<tr>
									<td align="center"> <?php echo $i+1;?></td>
									<td align="center"> <?php echo $result[$i]['mdc_name'];?></td>
									<td align="center"> <?php echo $result[$i]['mdc_type'];?></td>
									<td align="center"> <?php echo $result[$i]['mdc_cost'];?></td>
									<td align="center"> <?php echo $result[$i]['mdc_amount'];?></td>
									<td align="center"> <?php echo $result[$i]['price1'];?></td>
									<td align="center"> <?php echo $result[$i]['price2'];?></td>
									<td align="center"> <?php echo $result[$i]['price3'];?></td>
									<td align="center"> <?php echo $result[$i]['mdc_input'];?></td>
									<td align="center"> <?php echo $result[$i]['mdc_expire'];?></td>
									<td align="center"><div class="btn-group" data-toggle="buttons">
									<label class="btn btn-primary"> <input type="checkbox">
									<span class="glyphicon glyphicon-shopping-cart"></span></label></div></td>
								</tr>
							<?php }  ?>

									</tbody>
								</table>
							
						</form>

					</div> <!-- panel body -->
					</div> <!-- panel info -->
				</div> <!-- panel primary -->
			</div>
				
				</feldset><br/>
				
			</div> <!-- half right -->
	</div> <!-- content -->


	<div class="footer">
	
		<nav class="navbar navbar-default navbar-fixed-bottom" role="navigation">
			<ul class="nav nav-tabs navbar-right">
				<li><a>Alert</a></li>
			</ul>
			<ul class="nav nav-tabs navber-left">
			
				<li><b><p class="navbar-text">Search&nbsp;&nbsp;<span class="glyphicon glyphicon-search"></span></p></b></li>
				
				<form class="navbar-form navbar-left" role="search" name="keyword" id="keyword" action=" ">
        			<div class="form-group">
          				<input type="text" class="form-control" placeholder="Search">
        			</div>
        		<button type="submit" class="btn btn-primary"><span class="glyphicon glyphicon-send"></span></button>
      			</form>
				
			</ul>
		</nav>
		
	</div>

</body>

</html>